require('es6-promise').polyfill();
require('isomorphic-fetch');
export const changeOrderType=(order_type)=>{
    sessionStorage.setItem("order_type",order_type)
}

export const changeOrder_price=(order_price)=>{
    sessionStorage.setItem("order_price",order_price)
}
export const chargePay=(account,money,url)=>{
    fetch(url,
        {
            method: 'get',
            headers: {
                'Accept': 'application/json',
                "Content-Type": "application/json"
            },


        }
    ).then(function(response) {
        return response.json();
    }).then((json)=>{
        console.log(json);
        console.log(account);
        console.log(money)


    }).catch(function(ex) {
        console.log('parsing failed', ex)
    })
}


/*
export default class Store {

    @action changeOrderType(order_type) {
        this.order_type=order_type;
    }

    @action changeOrder_price(order_price) {
        this.order_price=order_price;
    }

    @action changeOrder_serverNum(order_serverNum) {
        this.order_serverNum=order_serverNum;
    }
    @action changeOrder_serverTime(order_serverTime){
        this.order_serverTime=order_serverTime;
    }
    @action changeOrder_serverAddress(order_serverAddress){
        this.order_serverAddress=order_serverAddress;
    }
    @action changeorder_serverPeriod(order_serverPeriod){
        this.order_serverPeriod=order_serverPeriod;
    }




}
*/
